const Sequelize = require('sequelize')
const sequelize = require('../db/sequelize')
/*
数据表一定命名复数
一般orm都会规范复数(sequelize,typeorm,typemongoose)
*/

let User = sequelize.define(
  'users',
  {
    id: {
      type: Sequelize.INTEGER(11),
      autoIncrement: true,
      primaryKey: true,
    },
    username: Sequelize.STRING(255),
    age: Sequelize.INTEGER(11),
  },
  {
    timestamps: false,
  }
)

module.exports = User
